General information
Category:
Databases,Tables, Views, Indexing and SQL syntax
Once you get your cursor open via SQLEXEC just do something like..
select mycusor
nFcount=AFIELDS(afld)
nFcount has the number of columns...
This works for SQLEXEC'd cursors (if you select * from table)
and for VFP tables.
On oracle you can do
SQL> select count(*) from dba_tab_columns where owner='FDB' and table_name='STYLES';
COUNT(*)
----------
196
SQL Server has a similar table but I don't know it's name...
Or use SQLCOLUMNS..
In ado I use..
ors=open(...)
nFcount=oRs.fields.count
HTH
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only