RegEx for parsing SQL query in C# -


I have to type the RegEx to parse the SQL join query that is given as a string. Can anyone help me because I'm new to this Thank you very much

This is my problem:

  string query = "selection table 1.column1, table1.column2, table2.coulmn1, table2.column2 table 1 inner Table 1.column5 = table2.column5 "on Join Table 1;  

What do I need by inserting all the important data into different variables:

class1 = table1 string class2 = table2 stringforeignkey1 = table1 .column5 string Join Oregiga 2 = Table 2.column5 list & lt; String & gt; Attributes1 = table1.column1, table1.column2 list & lt; String & gt; Attributes2 = table2.column1, table2.column2

// COMMENT

I realized that I made a mistake in the SQL query so there would be a section.

I can force a user to provide the right syntax, so that there is no problem.

The thing I have not mentioned is that more than one can join

>

By dragging on the comments, because I think this is the correct answer:

There is # 3 in the list of SQL Stuffs, parsing with a Regex Do not try, just behind and Use a bid-special, not a regex.


Comments

Popular posts from this blog

c# - sqlDecimal to decimal clr stored procedure Unable to cast object of type 'System.Data.SqlTypes.SqlDecimal' to type 'System.IConvertible' -

Calling GetGUIThreadInfo from Outlook VBA -

Obfuscating Python code? -