在Mysql中创建外键时,经常会遇到问题而失败,这是因为Mysql中还有很多细节需要我们去留意,我自己总结并查阅资料后列出了以下几种常见原因。 1. 两个字段的类型或者大小不严格匹配。例如,如果一个是int(10),那么外键也必须设置成int(10),而不是int(11),也不能是tinyint。另 ...
分类:
数据库 时间:
2017-11-06 15:32:16
阅读次数:
235
#include #include #pragma comment(lib, "D3D9.lib") #pragma comment(lib, "D3dx9.lib") #ifndef SAFE_RELEASE #define SAFE_RELEASE(p) if(p){p->Release();p... ...
分类:
其他好文 时间:
2017-11-06 14:53:06
阅读次数:
183
方法1: #include<cstring>#include<cstdio>using namespace std; struct Ball{ char color[20]; int num;}ball[1005]; int cnt=1; void count_num(char ch[]){ int ...
分类:
其他好文 时间:
2017-11-06 13:52:57
阅读次数:
149
Day1 T1玩具谜题 题目链接 简单模拟题,注意一下取余啊方向啊什么的就行了。 1 #include<cstdio> 2 #include<cstring> 3 #include<algorithm> 4 const int M=1e5+10; 5 using namespace std; 6 s ...
分类:
其他好文 时间:
2017-11-06 11:28:43
阅读次数:
172
T1 遭遇 1 #include <algorithm> 2 #include <cstdio> 3 #include <cmath> 4 5 inline void read(int &x) 6 { 7 x=0; register char ch=getchar(); 8 for(; ch>'9' ...
分类:
其他好文 时间:
2017-11-06 11:20:24
阅读次数:
207
Given a pattern and a string str, find if str follows the same pattern. Here follow means a full match, such that there is a bijection between a lette ...
分类:
其他好文 时间:
2017-11-06 11:19:48
阅读次数:
175
declare @tableName nvarchar(20) set @tableName = 'User' select b.name, a.value from sys.extended_properties a, sys.columns b where a.major_id = OBJECT... ...
分类:
数据库 时间:
2017-11-06 11:08:49
阅读次数:
232
在项目中通常用到了ListView控件,示例如下: create the listitem class ,eg; create Adapter class: Adapter类需要实现BaseAdapter, 并且需要在GetView method中指定,自定义ListItem的页面。得到listit ...
分类:
移动开发 时间:
2017-11-05 22:29:15
阅读次数:
183