473,698 Members | 2,274 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Dataset problem with column named "System"

The customer has a database with a column in a table named "System". I've
been using this method for years now - create a dataset (an .xsd file) for
the table. With a column named "System" in the dataset, it gives a
substantial number of compile errors.

To simplify the problem, add a Dataset with one table and one column called
"System" - below follows how it can be done:
Right click on the solution, click "Add", click "New Item" and then
"DataSet" and DataSet1 is OK for the name.
On the design sheet of DataSet1.xsd, right click. click "Add" and click
"DataTable" .
Right click on the DataTable and click "Add" and click "Column".
Rename the column from "Column1" to "System".
Build the project = compile errors.
Note that renaming the column to "[System]" rather than "System" does not
work either.
Sep 17 '07 #1
4 936
You are best-off avoiding things called "System"; unfortunately, it
means that anything with explicit namespace resolution (i.e. what the
designer spits out) will break, unless you start using aliases, or the
global prefix. Seriously - just cheat and call it SystemFlag or
similar; it just isn't worth the pain...

Marc

Sep 17 '07 #2
Hi Mark, thanks. Alias or global prefix sounds good - as this is just one
column, if you know how please let me know?
"Marc Gravell" <ma**********@g mail.comwrote in message
news:11******** **************@ 57g2000hsv.goog legroups.com...
You are best-off avoiding things called "System"; unfortunately, it
means that anything with explicit namespace resolution (i.e. what the
designer spits out) will break, unless you start using aliases, or the
global prefix. Seriously - just cheat and call it SystemFlag or
similar; it just isn't worth the pain...

Marc

Sep 17 '07 #3
Chris,

In my opinion is Marc his advice very good, spare you the time, with this
word you have the change that it will happen again later.

Cor

"Chris Botha" <ch************ *@hotmail.comsc hreef in bericht
news:O8******** ********@TK2MSF TNGP03.phx.gbl. ..
Hi Mark, thanks. Alias or global prefix sounds good - as this is just one
column, if you know how please let me know?
"Marc Gravell" <ma**********@g mail.comwrote in message
news:11******** **************@ 57g2000hsv.goog legroups.com...
>You are best-off avoiding things called "System"; unfortunately, it
means that anything with explicit namespace resolution (i.e. what the
designer spits out) will break, unless you start using aliases, or the
global prefix. Seriously - just cheat and call it SystemFlag or
similar; it just isn't worth the pain...

Marc

Sep 18 '07 #4
Demo below, but this is *not* a good idea; it will keep biting you,
and could make IDE functions like the forms designer very unreliable.

using SomeAlias = System;

class SystemDemo
{
bool System { get { return true; } }
void AliasDemo()
{
SomeAlias.Net.T ransportType type =
SomeAlias.Net.T ransportType.Tc p;
}
void GlobalDemo()
{
global::System. Net.TransportTy pe type =
global::System. Net.TransportTy pe.Tcp;
}
}

Sep 18 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
4181
by: Dave C. | last post by:
Hi, I have a few things on my databases which seem to be neither true system objects or user objects - notably a table called 'dtproperties' (created by Enterprise manager as I understand, relating to relationship graphing or something) and some stored procs begining with "dt_" (some kind of source control stuff, possible visual studio related). These show up when I use "exec sp_help 'databaseName'"
11
39885
by: Paminu | last post by:
Is there something like system("PAUSE") for linux?
0
1643
by: Asaf | last post by:
Hi, Sometimes I am getting the error "Cannot access a disposed object named "System.Net.TlsStream"." on the first attempt to do HTTP POST from a Windows 2003 Server. Is there a solution to this problem? Thanks, Asaf
5
6737
by: SMike | last post by:
I am getting the following error when sending a first http request: Cannot access a disposed object named "System.Net.TlsStream". After that everything sems to be fine untill the next long idle period. The code is below. Any helpful ideas would be appriciated. Encoding oEnc = System.Text.Encoding.GetEncoding(1252); oNc = new NetworkCredential(cUserName, cPassWord);
2
1340
by: Asaf | last post by:
Hi All, When doing HTTP POST to SSL URL I am getting the error: Cannot access a disposed object named "System.Net.TlsStream". I have found this code in the internet but it does not solve the problem. internal class AcceptAllCertificatePolicy : ICertificatePolicy {
14
2169
by: Ronald S. Cook | last post by:
I'm just curious how you would handle this. In the cable industry, Comcast is referred to as an "MSO" (multiple systems operator) meaning they own many cable systems. Therefore a solution must be architected to accommodate "System" as an entity. This means a table in the database named System, a class System, a web form System, etc. Since System is such a reserved word, how should we do this? To rename it "CableSystem" would bug as...
5
6488
by: CoderMarc | last post by:
Hi, I can not get the system pause to work in a simple program. Here is my program below: // i/o example #include <iostream> using namespace std; int main ()
5
1654
by: Chris Botha | last post by:
There is a database table with one of the columns named "System". When creating a new Dataset for this table, the project gives a huge number of compile errors. If I change the column name to be anything else than "System" and re-generate the Dataset, it works. The problem is that this is an existing database and there is no way that the column name will be changed.
4
1491
by: Chris Botha | last post by:
The customer has a database with a column in a table named "System". I've been using this method for years now - create a dataset (an .xsd file) for the table. With a column named "System" in the dataset, it gives a substantial number of compile errors. To simplify the problem, add a Dataset with one table and one column called "System" - below follows how it can be done: Right click on the solution, click "Add", click "New Item" and...
0
2037
by: tvnaidu | last post by:
Porting windows app to Linux, can I replace windows "_mkdir" with system("mkdir") in Linux?. system("mkdir(...)");
0
8600
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9156
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8860
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7712
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6518
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5860
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4361
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
3038
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2323
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.