Re: GROUP BY Clause Problem in VFP8
Date: Sat, 16 Oct 2004 16:22:58 -0700
VFP 8's SQL has been brought more into line with the the SQL standard. This
is correct operation of a SQL statement, though if you've gotten used to
VFP's earlier incorrect usage, it may not seem so.
So tell me, which ssn goes with which checkname in your select? It's
You can do SET ENGINEBEHAVIOR 70 to have it work in the old style, or you
can aggregate your ssn field with either a MIN or a MAX function. I do
believe that MAX(ssn) will give you the same results as previous versions of
Microsoft Visual FoxPro MVP
"Steve Meyerson" <firstname.lastname@example.org> wrote in message
> The following worked fine in VFP6:
> SELECT CheckName, Ssn ;
> FROM Payroll ;
> INTO TABLE TempPay ;
> GROUP BY CheckName
> In VFP8 I get the error msg:
> SQL: GROUP BY clause is missing or invalid
> even when I ran it from the command window.
> It will work ok if I SELECT only one field instead of 2 or more, but
> that's not acceptable.
> Payroll is a free dbf. I tried copying Payroll.dbf to "convert" it in
> case that was necessary. I also created a simple dbf in VFP8 and got
> the same behavior.
> Any clue what's going on? Thanks for any help.
> Steve Meyerson
- Re: Adding a UNIQUE constraint
... create view MyView ... create unique clustered index C_MyView on MyView (SSN) ... Columnist, SQL Server Professional ... from dbo.MyTable go create unique clustered index C_MyView on MyView go -- ...
- Re: VB6.0 - Data Format
... > SSN for each record or writing a module to handle it? ... This would be soooo much easier in SQL Server, just UPDATE mytable SET ssn = ... reasons I don't do Jet, ... >> automatically make the format of the data in that column consistent. ...
- Re: creating a primary key on peoples names??
... creating a function that will create a unique ID etc SQL ... Why would I use a function when an Identity key can create ... Perhaps last_name plus first_name plus ssn is what we will use...or ...
- Re: Need a So-Called SSN Encryption
... I have a SQL 2000 table with Social security numbers. ... allowed to use the exact SSN, we need to add 1 to each number in the ... the new SSN would be the new Member ID. ... State what version of SQL Server you are using and specify the content ...
- Re: Import into existing rows
... I need my query to look at the SSN from the Notes database and insert the approperiate date fields to the corrisponding date columns in my table. ... >If it would be easier to explain, you can use an example that would take the data from one sql table to another. ... Using proprietary Transact-SQL syntax (more compact, probably faster, ...