我们在postgreSQL中使用字符可变数组,并使用实体框架网络api检索列。但是当我将字段声明为import re
import getpass
while True:
my_str = getpass.getpass("Enter a password: ")
valid = True
if 8 > len(my_str):
valid = False
print("Password must have at least 8 characters")
if not re.search(r"[a-z]", my_str):
valid = False
print("Your Password must contain 1 lowercase letter")
if not re.search(r"[!@$&]", my_str):
valid = False
print("Your Password must contain 1 special character")
if not re.search(r"[A-Z]", my_str):
valid = False
print("Your Password must contain 1 uppercase letter")
if not re.search(r"\d", my_str):
valid = False
print("Your Password must contain 1 digit")
# This is the condition that checks the first character is a capital letter
if my_str and not my_str[0].isupper():
valid = False
print('First character must be a capital letter')
if valid:
break
时,实体框架会抛出"The specified type member 'xxx' is not supported in LINQ to Entities. Only initializers, entity members, and entity navigation properties are supported"
。我们还尝试输入string[]
。
如何在实体框架中映射来自postgres的数组列?