sqlparser / isf_notepad

SQL Formatter plugin for Notepad++
Apache License 2.0
77 stars 47 forks source link

Doesn't work of NP++ v6.7.5 on windows 8.1 #1

Open sqlparser opened 9 years ago

sqlparser commented 9 years ago

I am using v1.01 of the formatter in NP++ v6.7.5 on windows 8.1.

When I try to use the formatter for the following line of SQL it does nothing whatsoever – though if I run it through your website formatter it formats perfectly.

SELECT TOP 5000 n.name_id, COALESCE(n.e_mail_address,'') as Email_address, COALESCE(n.title_code,'') as Title_Code, COALESCE(n.first_name,'') as First_Name, COALESCE(n.last_name,'') as Last_Name, n.ok_to_email, n.ok_to_sell_name,a.country_id,(MAX(li.update_dtm)) as Last_Purchase_date,(COUNT(DISTINCT li. order_number)) as Number_Of_purchases,COALESCE(n.promotion_id,'') as Promotion_Id,SUM(li.product_price) AS Life_time_spend FROM line_item li WITH(nolock) INNER JOIN names n WITH(nolock) ON li.name_id=n.name_id INNER JOIN Addresses A WITH(Nolock) on li.address_id=a.address_id INNER JOIN Orders o ON o.order_number = li.order_number WHERE n.company_id IS NULL AND li.parent_sku IS NULL AND o.Catalog_id NOT IN ('12516','STAPLES','12502','EZIBUY','EZIBUYNZ1','32211','12821','42114','JDWUK','JDWIRE','UKWHOL40','32537','32538','SKYMALL','CUTEKID','11125','11123','US208','UKWHOL40',) AND coalesce(n.e_mail_address,'') <>'' GROUP BY n.Name_id, n.e_mail_address, n.title_code, n.first_name, n.last_name, n.ok_to_email, n.ok_to_sell_name, n.promotion_id, a.country_id ORDER BY Life_time_spend DESC

Even if I try to format some really simple SQL such as the following it still does nothing:

select * from table1 where surname = 'smith' and age > 50 order by cust_id

I have also tried removing the fo.json file from the plugins/config/sqlformat folder in case that was causing the issue but it made no difference.

cnfree commented 8 years ago

I can't reproduce your problem in NP++ v6.7.5 on windows 8.1. Please check your network, it should enable to access the website http://www.gudusoft.com/format.php.

image