Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problem with BigInt?
Message
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Problem with BigInt?
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Miscellaneous
Thread ID:
01527849
Message ID:
01527849
Views:
222
Hi everybody,

Using DSN and SQLExec from SQL Server to VFP I'm running the following code:
 TEXT TO lcSQL TEXTMERGE noshow
  DECLARE @MaxSize INT, @MaxSizeDesc varchar(10)
  SELECT @MaxSize = CASE WHEN SERVERPROPERTY('ProductVersion') > '10.5' THEN 10 * 1024 * 1024 -- 10GB for SQL Server 2008 R2 Express 
			ELSE 4 * 1024 * 1024 END,
		 @MaxSizeDesc = CASE WHEN SERVERPROPERTY('ProductVersion') > '10.5' THEN '10 GB' 
			ELSE '4 GB' END

  SELECT SUM(SIZE*8) AS SizeKB, @MaxSize AS MaxSize, @MaxSizeDesc as MaxSizeDesc
   FROM sys.master_files
    WHERE DB_NAME(database_id) = <<VFP2SQL(this.cDbName)>> AND type = 0
  ENDTEXT   
  mysqlexec(m.lcSQL, 'csrTemp', program())
I receive perfect results in SQL Server, but in VFP the SizeKB field returns NULL. Is it because VFP can not handle Bigint ? Should I try converting this value to decimal instead ?

Thanks in advance.
If it's not broken, fix it until it is.


My Blog
Next
Reply
Map
View

Click here to load this message in the networking platform