main
Inga 🏳‍🌈 14 years ago
parent 57c36e7bcc
commit 11e2cda727
  1. 8
      FLocal.sln
  2. 26
      tmp/Program.cs
  3. 36
      tmp/Properties/AssemblyInfo.cs
  4. 63
      tmp/tmp.csproj

@ -13,6 +13,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MySql.Data", "ThirdParty\my
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Builder", "Builder\Builder.csproj", "{D8D6EFEC-76D7-4870-BD71-C90FA6D7368A}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "tmp", "tmp\tmp.csproj", "{BDC42785-41F7-4C32-880E-A6C43A448054}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@ -59,6 +61,12 @@ Global
{D8D6EFEC-76D7-4870-BD71-C90FA6D7368A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D8D6EFEC-76D7-4870-BD71-C90FA6D7368A}.Release|Any CPU.Build.0 = Release|Any CPU
{D8D6EFEC-76D7-4870-BD71-C90FA6D7368A}.Release|x86.ActiveCfg = Release|Any CPU
{BDC42785-41F7-4C32-880E-A6C43A448054}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{BDC42785-41F7-4C32-880E-A6C43A448054}.Debug|Any CPU.Build.0 = Debug|Any CPU
{BDC42785-41F7-4C32-880E-A6C43A448054}.Debug|x86.ActiveCfg = Debug|Any CPU
{BDC42785-41F7-4C32-880E-A6C43A448054}.Release|Any CPU.ActiveCfg = Release|Any CPU
{BDC42785-41F7-4C32-880E-A6C43A448054}.Release|Any CPU.Build.0 = Release|Any CPU
{BDC42785-41F7-4C32-880E-A6C43A448054}.Release|x86.ActiveCfg = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

@ -0,0 +1,26 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MySql.Data.MySqlClient;
namespace tmp {
class Program {
static void Main(string[] args) {
string fieldToSelect = args[0];
using(MySqlConnection connection = new MySqlConnection("Protocol=pipe;Charset=utf8;Database=flocal_production;Username=flocalp;Password=flocalp")) {
connection.Open();
using(MySqlCommand command = connection.CreateCommand()) {
command.CommandText = "SELECT `" + fieldToSelect + "` FROM `boards`";
Console.WriteLine("Command: " + command.CommandText);
using(MySqlDataReader reader = command.ExecuteReader()) {
Console.WriteLine("Command executed");
while(reader.Read()) {
Console.WriteLine("Data read");
}
}
}
}
}
}
}

@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("tmp")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("tmp")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2010")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("8f97b235-2bd3-4835-8c64-6d96926c5405")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

@ -0,0 +1,63 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>9.0.30729</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{BDC42785-41F7-4C32-880E-A6C43A448054}</ProjectGuid>
<OutputType>Exe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>tmp</RootNamespace>
<AssemblyName>tmp</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="MySql.Data, Version=6.3.2.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>C:\Program Files (x86)\MySQL\MySQL Connector Net 6.3.2\Assemblies\v2.0\MySql.Data.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Xml.Linq">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data.DataSetExtensions">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
Loading…
Cancel
Save